package com.zhentao.datacontrol.domain.dto;

import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;

import java.util.List;

public class RuleGroupDTO {

    private Long id;

    @NotBlank(message = "分组名称不能为空")
    private String groupName;

    private Long parentId;

    @NotNull(message = "分组层级不能为空")
    private Integer groupLevel;

    private Integer sortOrder;
    private String description;

    // 非数据库字段
    private List<RuleGroupDTO> children;
    private String parentName;

    // Getters and Setters
    public Long getId() { return id; }
    public void setId(Long id) { this.id = id; }

    public String getGroupName() { return groupName; }
    public void setGroupName(String groupName) { this.groupName = groupName; }

    public Long getParentId() { return parentId; }
    public void setParentId(Long parentId) { this.parentId = parentId; }

    public Integer getGroupLevel() { return groupLevel; }
    public void setGroupLevel(Integer groupLevel) { this.groupLevel = groupLevel; }

    public Integer getSortOrder() { return sortOrder; }
    public void setSortOrder(Integer sortOrder) { this.sortOrder = sortOrder; }

    public String getDescription() { return description; }
    public void setDescription(String description) { this.description = description; }

    public List<RuleGroupDTO> getChildren() { return children; }
    public void setChildren(List<RuleGroupDTO> children) { this.children = children; }

    public String getParentName() { return parentName; }
    public void setParentName(String parentName) { this.parentName = parentName; }
}
